package com.liliudong.keelflower.common.core.exception;

import com.liliudong.keelflower.common.core.constants.HttpStatus;
import lombok.Getter;

/**
 * @author Liudong.li
 */
@Getter
public class BusinessException extends RuntimeException {

    private HttpStatus httpStatus;

    public BusinessException(String message) {
        super(message);
        this.httpStatus = HttpStatus.EXCEPTION;
    }

    public BusinessException(HttpStatus httpStatus) {
        super(httpStatus.msg);
        this.httpStatus = httpStatus;
    }

    public BusinessException(String message, Throwable cause) {
        super(message, cause);
    }

}
